using UniversalAdmin.Domain.Entities;

namespace UniversalAdmin.Domain.Repositories;

public interface IChatHistoryRepository : IRepository<ChatHistory>
{
    Task<(IEnumerable<ChatHistory> Histories, int TotalCount)> GetPagedByUserIdAsync(Guid userId, int page, int pageSize);
    Task<IEnumerable<ChatHistory>> GetBySessionIdAsync(Guid sessionId);
    Task<IEnumerable<ChatHistory>> GetRecentAsync(Guid userId, int count = 10);
    Task<(IEnumerable<ChatHistory> Histories, int TotalCount)> SearchAsync(Guid userId, string keyword, int page, int pageSize);
    Task DeleteBySessionIdAsync(Guid sessionId);
    Task<int> GetSessionCountAsync(Guid userId);
}